import uniHelper from '@uni-helper/eslint-config';

export default uniHelper({
  unocss: true,
  vue: true,
  markdown: false,
  typescript: true,
  ignores: [
    '.vscode',
    '.hbuilderx',
    'nativeplugins',
    'src/uni_modules/',
    'dist',
    'auto-import.d.ts',
    'uni-pages.d.ts',
    'src/pages.json',
    'src/manifest.json',
    'src/static/**'
  ],
  rules: {
    'unused-imports/no-unused-imports': ['error'],
    'ts/no-use-before-define': 'off',
    'node/prefer-global/process': 'off',
    'style/semi': ['error', 'always'],
    'style/comma-dangle': ['error', 'never'],
    'style/arrow-parens': ['error', 'as-needed'],
    'no-console': 'off',
    // 'no-unused-vars': 'off',
    // 'vue/no-unused-refs': 'off',
    // 'unused-imports/no-unused-vars': 'off',
    'eslint-comments/no-unlimited-disable': 'off',
    'jsdoc/check-param-names': 'off',
    'jsdoc/require-returns-description': 'off',
    'ts/no-empty-object-type': 'off',
    'no-extend-native': 'off'
  },
  formatters: {
    /**
     * Format CSS, LESS, SCSS files, also the `<style>` blocks in Vue
     * By default uses Prettier
     */
    css: true,
    /**
     * Format HTML files
     * By default uses Prettier
     */
    html: true
  }
});
